<script setup lang="ts">
import { ref } from 'vue';

const score = ref(90)
const isShow = ref(false)
const toggle = () => {
  isShow.value = !isShow.value
}
</script>

<template>
  <div>
    <div>分数: {{ score }}</div>
    <button v-on:click="score++">点我++</button>
    <!-- v-on:事件名 简写 @事件名 -->
    <button @click="score--">点我--</button>
    <hr>
    <button @click="toggle">切换显示</button>
    <img v-show="isShow" src="./assets/logo.svg" width="300" alt="">
  </div>
</template>

<style></style>
